]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
network: use the VPN state to compute the icon for VPN items
authorGiovanni Campagna <gcampagna@src.gnome.org>
Mon, 19 Aug 2013 21:30:06 +0000 (23:30 +0200)
committerGiovanni Campagna <gcampagna@src.gnome.org>
Sat, 31 Aug 2013 16:52:01 +0000 (18:52 +0200)
We watch changes in the VPN state, not the active connection state,
so if we use the active connection state, we might miss an update
(because the VPN property is notified before the other one)

https://bugzilla.gnome.org/show_bug.cgi?id=706262

js/ui/status/network.js

index 20157f4fa486db5a3dc977b2ae414c2890fc0ed6..f08f57d76ae1a7286ea30406e6951f6c8ec08b39 100644 (file)
@@ -1137,7 +1137,7 @@ const NMVPNConnectionItem = new Lang.Class({
 
     getIndicatorIcon: function() {
         if (this._activeConnection) {
-            if (this._activeConnection.state == NetworkManager.ActiveConnectionState.ACTIVATING)
+            if (this._activeConnection.vpn_state < NetworkManager.VPNConnectionState.ACTIVATED)
                 return 'network-vpn-acquiring-symbolic';
             else
                 return 'network-vpn-symbolic';